import instance from './http.js'

const api = {
  getCountByType(params) {
    return instance.get('/admin/upms/ground/countByType', params)
  },
  getGroundList(params) {
    return instance.post('/admin/upms/ground/list', params)
  },
  getProjectList(params) {
    return instance.post('/admin/upms/project/page', params)
  },
  getActivitiesList(params) {
    return instance.post('/admin/upms/activity/page', params)
  },
  getCountByActiStatus(params) {
    return instance.post('/admin/upms/activity/countByStatus', params)
  },
  getDicByCode(params) {
    return instance.get('/admin/upms/globalDict/listDict', params)
  },
  getInfoList(params) {
    return instance.post('/admin/upms/info/page', params)
  },
  getActivityDetail(params, config) {
    return instance.post('/admin/upms/activity/info', params, config)
  },
  getGroundDetail(params, config) {
    return instance.get('/admin/upms/ground/view', params, config)
  },
  getInfoDetail(params, config) {
    return instance.post('/admin/upms/info/info', params, config)
  },
  getProjectDetail(params, config){
    return instance.post('/admin/upms/project/info', params, config)
  },
  getNearGroundData(params,config){
    return instance.post('/admin/upms/ground/nearByGround', params, config)
  },
  getCountByArea(params,config){
    return instance.get('/admin/upms/ground/countByDistrict', params, config)
  },
  getGroundChildCount(params, config){
    return instance.get('/admin/upms/ground/countByGround', params, config)
  }
}

export default api
